package com.cnap.multiclouldmgmt.repository.cnap;

import com.cnap.multiclouldmgmt.model.microSvc.GatewayLogModel;
import com.cnap.multiclouldmgmt.model.microSvc.MicroServicePO;
import com.cnap.multiclouldmgmt.model.microSvc.alg.IndicatorHistoryModel;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.Date;
import java.util.List;

/**
 * @author dyq
 * 对接数据库操作语句
 */
@Mapper
public interface MicroSvcMapper {

    List<MicroServicePO> getAllMicroService(@Param("userName")String userName,@Param("svcName")String svcName);

    List<GatewayLogModel> getGatewayLogByTime(@Param("microSvcId")String microSvcId,@Param("createTime")Date createTime);

    IndicatorHistoryModel getIndicatorIdCheckKey(@Param("indicatorId")String indicatorId);

    MicroServicePO getMicroServiceByUserNameId(@Param("userName")String userName,@Param("svcId")String svcId);

    MicroServicePO getMicroServiceByUserNameSvcName(@Param("userName")String userName,@Param("svcName")String svcName,
                                                    @Param("svcId")String svcId);

    String getBusinessScenceBySvcId(@Param("microSvcId")String microSvcId);
}
